package com.guoxin.part1.chapter5;

import java.util.List;
import java.util.concurrent.TimeoutException;

/**
 * 定义Lock接口
 *
 * @author guoxin
 * @date 2019/8/28
 */
public interface Lock {

    void lock() throws InterruptedException;

    void lock(long mills) throws InterruptedException,TimeoutException;

    void unlock();

    List<Thread> getBlockedThreads();

}
